package com.ourteam.system.dao;

import net.dao.BaseQueryBean;
import net.dao.BaseWhereCriterion;
import net.dao.IDataAccessInterface;

import org.apache.commons.lang.StringUtils;

import java.util.Arrays;
import java.util.List;
import java.util.Map;


/**
 * Template Name : DAO查询对象
 * Template Version : 1
 * Template Last Modfiy Date : Sat Aug 19 10:06:32 CST 2017
 * Auto Generate Date : 2018-07-31 15:13:27
  * Warning ! This file will be overwrite when regenerate !
  *
 */
public class SysRoleResourceRelateDAOQueryBean extends BaseQueryBean {
    public SysRoleResourceRelateDAOQueryBean() {
        super();
    }

    public SysRoleResourceRelateDAOQueryBean(BaseQueryBean aQueryBean) {
        super(aQueryBean);
    }

    public SysRoleResourceRelateDAOQueryBean(BaseQueryBean aQueryBean,
        Map tableReplaceMap) {
        super(aQueryBean, tableReplaceMap);
    }

    public Criteria createCriteria() {
        Criteria criteria = createCriteriaInternal();

        if (oredCriteria.size() == 0) {
            oredCriteria.add(criteria);
        }

        return criteria;
    }

    protected Criteria createCriteriaInternal() {
        return new Criteria(this);
    }

    public void addIdSelectProperty() {
        addIdSelectProperty("id");
    }

    public void addIdSelectProperty(String aAlias) {
        if (StringUtils.isNotBlank(aAlias)) {
            addSelectProperty(ISysRoleResourceRelateDAO.Id, aAlias);
        } else {
            addSelectProperty(ISysRoleResourceRelateDAO.Id, "id");
        }
    }

    public void addRelateCodeSelectProperty() {
        addRelateCodeSelectProperty("relateCode");
    }

    public void addRelateCodeSelectProperty(String aAlias) {
        if (StringUtils.isNotBlank(aAlias)) {
            addSelectProperty(ISysRoleResourceRelateDAO.RelateCode, aAlias);
        } else {
            addSelectProperty(ISysRoleResourceRelateDAO.RelateCode, "relateCode");
        }
    }

    public void addRelateNameSelectProperty() {
        addRelateNameSelectProperty("relateName");
    }

    public void addRelateNameSelectProperty(String aAlias) {
        if (StringUtils.isNotBlank(aAlias)) {
            addSelectProperty(ISysRoleResourceRelateDAO.RelateName, aAlias);
        } else {
            addSelectProperty(ISysRoleResourceRelateDAO.RelateName, "relateName");
        }
    }

    public void addRemarksSelectProperty() {
        addRemarksSelectProperty("remarks");
    }

    public void addRemarksSelectProperty(String aAlias) {
        if (StringUtils.isNotBlank(aAlias)) {
            addSelectProperty(ISysRoleResourceRelateDAO.Remarks, aAlias);
        } else {
            addSelectProperty(ISysRoleResourceRelateDAO.Remarks, "remarks");
        }
    }

    public void addStatusSelectProperty() {
        addStatusSelectProperty("status");
    }

    public void addStatusSelectProperty(String aAlias) {
        if (StringUtils.isNotBlank(aAlias)) {
            addSelectProperty(ISysRoleResourceRelateDAO.Status, aAlias);
        } else {
            addSelectProperty(ISysRoleResourceRelateDAO.Status, "status");
        }
    }

    public void addSysResourceIdSelectProperty() {
        addSysResourceIdSelectProperty("sysResourceId");
    }

    public void addSysResourceIdSelectProperty(String aAlias) {
        if (StringUtils.isNotBlank(aAlias)) {
            addSelectProperty(ISysRoleResourceRelateDAO.SysResourceId, aAlias);
        } else {
            addSelectProperty(ISysRoleResourceRelateDAO.SysResourceId,
                "sysResourceId");
        }
    }

    public void addSysRoleIdSelectProperty() {
        addSysRoleIdSelectProperty("sysRoleId");
    }

    public void addSysRoleIdSelectProperty(String aAlias) {
        if (StringUtils.isNotBlank(aAlias)) {
            addSelectProperty(ISysRoleResourceRelateDAO.SysRoleId, aAlias);
        } else {
            addSelectProperty(ISysRoleResourceRelateDAO.SysRoleId, "sysRoleId");
        }
    }

    public void addSysRoleNameSelectProperty() {
        addSysRoleNameSelectProperty("sysRoleName");
    }

    public void addSysRoleNameSelectProperty(String aAlias) {
        if (StringUtils.isNotBlank(aAlias)) {
            addSelectProperty(ISysRoleResourceRelateDAO.SysRoleName, aAlias);
        } else {
            addSelectProperty(ISysRoleResourceRelateDAO.SysRoleName,
                "sysRoleName");
        }
    }

    public void addSysResourceTitleKeySelectProperty() {
        addSysResourceTitleKeySelectProperty("sysResourceTitleKey");
    }

    public void addSysResourceTitleKeySelectProperty(String aAlias) {
        if (StringUtils.isNotBlank(aAlias)) {
            addSelectProperty(ISysRoleResourceRelateDAO.SysResourceTitleKey,
                aAlias);
        } else {
            addSelectProperty(ISysRoleResourceRelateDAO.SysResourceTitleKey,
                "sysResourceTitleKey");
        }
    }

    public void addAllSelectProperties() {
        addIdSelectProperty();

        addRelateCodeSelectProperty();

        addRelateNameSelectProperty();

        addRemarksSelectProperty();

        addStatusSelectProperty();

        addSysResourceIdSelectProperty();

        addSysRoleIdSelectProperty();

        addSysRoleNameSelectProperty();

        addSysResourceTitleKeySelectProperty();
    }

    public static class Criteria extends BaseWhereCriterion<SysRoleResourceRelateDAOQueryBean> {
        protected Criteria(SysRoleResourceRelateDAOQueryBean aParentObject) {
            super(aParentObject);
        }

        public Criteria andIdIsNull() {
            addCriterion(ISysRoleResourceRelateDAO.Id + " is null");

            return this;
        }

        public Criteria andIdIsNotNull() {
            addCriterion(ISysRoleResourceRelateDAO.Id + " is not null");

            return this;
        }

        public Criteria andIdIsNotEmpty() {
            addCriterion(ISysRoleResourceRelateDAO.Id + " is not null AND " +
                ISysRoleResourceRelateDAO.Id + " <> ''");

            return this;
        }

        public Criteria andIdIsEmpty() {
            addCriterion("(" + ISysRoleResourceRelateDAO.Id + " is null OR " +
                ISysRoleResourceRelateDAO.Id + " = '')");

            return this;
        }

        public Criteria andIdEqualTo(long value) {
            return andIdEqualTo(Long.valueOf(value));
        }

        public Criteria andIdEqualTo(java.lang.Long value) {
            addCriterion(ISysRoleResourceRelateDAO.Id + " = ", value, "id");

            return this;
        }

        public Criteria andIdEqualToForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.Id);
            str.append(" = ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andIdEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.Id + " = ", subQueryBean, dao);

            return this;
        }

        public Criteria andIdNotEqualTo(long value) {
            return andIdNotEqualTo(Long.valueOf(value));
        }

        public Criteria andIdNotEqualTo(java.lang.Long value) {
            addCriterion(ISysRoleResourceRelateDAO.Id + " <>", value, "id");

            return this;
        }

        public Criteria andIdNotEqualToOrIsNull(long value) {
            return andIdNotEqualToOrIsNull(Long.valueOf(value));
        }

        public Criteria andIdNotEqualToOrIsNull(java.lang.Long value) {
            addCriterion(ISysRoleResourceRelateDAO.Id + " is null OR " +
                ISysRoleResourceRelateDAO.Id + " <>", value, "id");

            return this;
        }

        public Criteria andIdNotEqualToForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.Id);
            str.append(" <> ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andIdNotEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.Id + " <> ", subQueryBean,
                dao);

            return this;
        }

        public Criteria andIdGreaterThan(long value) {
            return andIdGreaterThan(Long.valueOf(value));
        }

        public Criteria andIdGreaterThan(java.lang.Long value) {
            addCriterion(ISysRoleResourceRelateDAO.Id + " >", value, "id");

            return this;
        }

        public Criteria andIdGreaterThanForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.Id);
            str.append(" > ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andIdGreaterThan(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.Id + " > ", subQueryBean, dao);

            return this;
        }

        public Criteria andIdGreaterThanOrEqualTo(long value) {
            return andIdGreaterThanOrEqualTo(Long.valueOf(value));
        }

        public Criteria andIdGreaterThanOrEqualTo(java.lang.Long value) {
            addCriterion(ISysRoleResourceRelateDAO.Id + " >=", value, "id");

            return this;
        }

        public Criteria andIdGreaterThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.Id);
            str.append(" >= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andIdGreaterThanOrEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.Id + " >= ", subQueryBean,
                dao);

            return this;
        }

        public Criteria andIdLessThan(long value) {
            return andIdLessThan(Long.valueOf(value));
        }

        public Criteria andIdLessThan(java.lang.Long value) {
            addCriterion(ISysRoleResourceRelateDAO.Id + " <", value, "id");

            return this;
        }

        public Criteria andIdLessThanForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.Id);
            str.append(" < ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andIdLessThan(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.Id + " < ", subQueryBean, dao);

            return this;
        }

        public Criteria andIdLessThanOrEqualTo(long value) {
            return andIdLessThanOrEqualTo(Long.valueOf(value));
        }

        public Criteria andIdLessThanOrEqualTo(java.lang.Long value) {
            addCriterion(ISysRoleResourceRelateDAO.Id + " <=", value, "id");

            return this;
        }

        public Criteria andIdLessThanOrEqualToForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.Id);
            str.append(" <= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andIdLessThanOrEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.Id + " <= ", subQueryBean,
                dao);

            return this;
        }

        public Criteria andIdIn(long[] values) {
            if (values.length == 1) {
                return andIdEqualTo((java.lang.Long) values[0]);
            } else {
                addCriterion(ISysRoleResourceRelateDAO.Id + " in", values, "id");

                return this;
            }
        }

        public Criteria andIdNotIn(long[] values) {
            if (values.length == 1) {
                return andIdNotEqualTo((java.lang.Long) values[0]);
            } else {
                addCriterion(ISysRoleResourceRelateDAO.Id + " not in", values,
                    "id");

                return this;
            }
        }

        public Criteria andIdIn(List<java.lang.Long> values) {
            if (values.size() == 1) {
                return andIdEqualTo(values.get(0));
            } else {
                addCriterion(ISysRoleResourceRelateDAO.Id + " in", values, "id");

                return this;
            }
        }

        public Criteria andIdNotIn(List<java.lang.Long> values) {
            if (values.size() == 1) {
                return andIdNotEqualTo(values.get(0));
            } else {
                addCriterion(ISysRoleResourceRelateDAO.Id + " not in", values,
                    "id");

                return this;
            }
        }

        public Criteria andIdIn(java.lang.Long[] values) {
            if (values.length == 1) {
                return andIdEqualTo(values[0]);
            } else {
                addCriterion(ISysRoleResourceRelateDAO.Id + " in",
                    Arrays.asList(values), "id");

                return this;
            }
        }

        public Criteria andIdNotIn(java.lang.Long[] values) {
            if (values.length == 1) {
                return andIdNotEqualTo(values[0]);
            } else {
                addCriterion(ISysRoleResourceRelateDAO.Id + " not in",
                    Arrays.asList(values), "id");

                return this;
            }
        }

        public Criteria andIdIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.Id + " in ", subQueryBean,
                dao);

            return this;
        }

        public Criteria andIdNotIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.Id + " not in ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andIdBetween(long value1, long value2) {
            addCriterion(ISysRoleResourceRelateDAO.Id + " between", value1,
                value2, "id");

            return this;
        }

        public Criteria andIdBetween(java.lang.Long value1,
            java.lang.Long value2) {
            addCriterion(ISysRoleResourceRelateDAO.Id + " between", value1,
                value2, "id");

            return this;
        }

        public Criteria andIdNotBetween(long value1, long value2) {
            addCriterion(ISysRoleResourceRelateDAO.Id + " not between", value1,
                value2, "id");

            return this;
        }

        public Criteria andIdNotBetween(java.lang.Long value1,
            java.lang.Long value2) {
            addCriterion(ISysRoleResourceRelateDAO.Id + " not between", value1,
                value2, "id");

            return this;
        }

        public Criteria andRelateCodeIsNull() {
            addCriterion(ISysRoleResourceRelateDAO.RelateCode + " is null");

            return this;
        }

        public Criteria andRelateCodeIsNotNull() {
            addCriterion(ISysRoleResourceRelateDAO.RelateCode + " is not null");

            return this;
        }

        public Criteria andRelateCodeIsNotEmpty() {
            addCriterion(ISysRoleResourceRelateDAO.RelateCode +
                " is not null AND " + ISysRoleResourceRelateDAO.RelateCode +
                " <> ''");

            return this;
        }

        public Criteria andRelateCodeIsEmpty() {
            addCriterion("(" + ISysRoleResourceRelateDAO.RelateCode +
                " is null OR " + ISysRoleResourceRelateDAO.RelateCode +
                " = '')");

            return this;
        }

        public Criteria andRelateCodeEqualTo(String value) {
            addCriterion(ISysRoleResourceRelateDAO.RelateCode + " = ", value,
                "relateCode");

            return this;
        }

        public Criteria andRelateCodeEqualToForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.RelateCode);
            str.append(" = ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andRelateCodeEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.RelateCode + " = ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andRelateCodeNotEqualTo(String value) {
            addCriterion(ISysRoleResourceRelateDAO.RelateCode + " <>", value,
                "relateCode");

            return this;
        }

        public Criteria andRelateCodeNotEqualToOrIsNull(String value) {
            addCriterion(ISysRoleResourceRelateDAO.RelateCode + " is null OR " +
                ISysRoleResourceRelateDAO.RelateCode + " <>", value,
                "relateCode");

            return this;
        }

        public Criteria andRelateCodeNotEqualToForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.RelateCode);
            str.append(" <> ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andRelateCodeNotEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.RelateCode + " <> ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andRelateCodeGreaterThan(String value) {
            addCriterion(ISysRoleResourceRelateDAO.RelateCode + " >", value,
                "relateCode");

            return this;
        }

        public Criteria andRelateCodeGreaterThanForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.RelateCode);
            str.append(" > ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andRelateCodeGreaterThan(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.RelateCode + " > ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andRelateCodeGreaterThanOrEqualTo(String value) {
            addCriterion(ISysRoleResourceRelateDAO.RelateCode + " >=", value,
                "relateCode");

            return this;
        }

        public Criteria andRelateCodeGreaterThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.RelateCode);
            str.append(" >= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andRelateCodeGreaterThanOrEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.RelateCode + " >= ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andRelateCodeLessThan(String value) {
            addCriterion(ISysRoleResourceRelateDAO.RelateCode + " <", value,
                "relateCode");

            return this;
        }

        public Criteria andRelateCodeLessThanForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.RelateCode);
            str.append(" < ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andRelateCodeLessThan(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.RelateCode + " < ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andRelateCodeLessThanOrEqualTo(String value) {
            addCriterion(ISysRoleResourceRelateDAO.RelateCode + " <=", value,
                "relateCode");

            return this;
        }

        public Criteria andRelateCodeLessThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.RelateCode);
            str.append(" <= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andRelateCodeLessThanOrEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.RelateCode + " <= ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andRelateCodeLike(String value) {
            StringBuffer buffer = new StringBuffer("%");
            buffer.append(value);
            buffer.append("%");
            addCriterion(ISysRoleResourceRelateDAO.RelateCode + " like",
                buffer.toString(), "relateCode");

            return this;
        }

        public Criteria andRelateCodeNotLike(String value) {
            StringBuffer buffer = new StringBuffer("%");
            buffer.append(value);
            buffer.append("%");
            addCriterion(ISysRoleResourceRelateDAO.RelateCode + " not like",
                buffer.toString(), "relateCode");

            return this;
        }

        public Criteria andRelateCodeIn(List<String> values) {
            if (values.size() == 1) {
                return andRelateCodeEqualTo(values.get(0));
            } else {
                addCriterion(ISysRoleResourceRelateDAO.RelateCode + " in",
                    values, "relateCode");

                return this;
            }
        }

        public Criteria andRelateCodeNotIn(List<String> values) {
            if (values.size() == 1) {
                return andRelateCodeNotEqualTo(values.get(0));
            } else {
                addCriterion(ISysRoleResourceRelateDAO.RelateCode + " not in",
                    values, "relateCode");

                return this;
            }
        }

        public Criteria andRelateCodeIn(String[] values) {
            if (values.length == 1) {
                return andRelateCodeEqualTo(values[0]);
            } else {
                addCriterion(ISysRoleResourceRelateDAO.RelateCode + " in",
                    Arrays.asList(values), "relateCode");

                return this;
            }
        }

        public Criteria andRelateCodeNotIn(String[] values) {
            if (values.length == 1) {
                return andRelateCodeNotEqualTo(values[0]);
            } else {
                addCriterion(ISysRoleResourceRelateDAO.RelateCode + " not in",
                    Arrays.asList(values), "relateCode");

                return this;
            }
        }

        public Criteria andRelateCodeIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.RelateCode + " in ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andRelateCodeNotIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.RelateCode + " not in ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andRelateCodeBetween(String value1, String value2) {
            addCriterion(ISysRoleResourceRelateDAO.RelateCode + " between",
                value1, value2, "relateCode");

            return this;
        }

        public Criteria andRelateCodeNotBetween(String value1, String value2) {
            addCriterion(ISysRoleResourceRelateDAO.RelateCode + " not between",
                value1, value2, "relateCode");

            return this;
        }

        public Criteria andRelateNameIsNull() {
            addCriterion(ISysRoleResourceRelateDAO.RelateName + " is null");

            return this;
        }

        public Criteria andRelateNameIsNotNull() {
            addCriterion(ISysRoleResourceRelateDAO.RelateName + " is not null");

            return this;
        }

        public Criteria andRelateNameIsNotEmpty() {
            addCriterion(ISysRoleResourceRelateDAO.RelateName +
                " is not null AND " + ISysRoleResourceRelateDAO.RelateName +
                " <> ''");

            return this;
        }

        public Criteria andRelateNameIsEmpty() {
            addCriterion("(" + ISysRoleResourceRelateDAO.RelateName +
                " is null OR " + ISysRoleResourceRelateDAO.RelateName +
                " = '')");

            return this;
        }

        public Criteria andRelateNameEqualTo(String value) {
            addCriterion(ISysRoleResourceRelateDAO.RelateName + " = ", value,
                "relateName");

            return this;
        }

        public Criteria andRelateNameEqualToForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.RelateName);
            str.append(" = ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andRelateNameEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.RelateName + " = ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andRelateNameNotEqualTo(String value) {
            addCriterion(ISysRoleResourceRelateDAO.RelateName + " <>", value,
                "relateName");

            return this;
        }

        public Criteria andRelateNameNotEqualToOrIsNull(String value) {
            addCriterion(ISysRoleResourceRelateDAO.RelateName + " is null OR " +
                ISysRoleResourceRelateDAO.RelateName + " <>", value,
                "relateName");

            return this;
        }

        public Criteria andRelateNameNotEqualToForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.RelateName);
            str.append(" <> ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andRelateNameNotEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.RelateName + " <> ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andRelateNameGreaterThan(String value) {
            addCriterion(ISysRoleResourceRelateDAO.RelateName + " >", value,
                "relateName");

            return this;
        }

        public Criteria andRelateNameGreaterThanForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.RelateName);
            str.append(" > ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andRelateNameGreaterThan(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.RelateName + " > ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andRelateNameGreaterThanOrEqualTo(String value) {
            addCriterion(ISysRoleResourceRelateDAO.RelateName + " >=", value,
                "relateName");

            return this;
        }

        public Criteria andRelateNameGreaterThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.RelateName);
            str.append(" >= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andRelateNameGreaterThanOrEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.RelateName + " >= ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andRelateNameLessThan(String value) {
            addCriterion(ISysRoleResourceRelateDAO.RelateName + " <", value,
                "relateName");

            return this;
        }

        public Criteria andRelateNameLessThanForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.RelateName);
            str.append(" < ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andRelateNameLessThan(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.RelateName + " < ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andRelateNameLessThanOrEqualTo(String value) {
            addCriterion(ISysRoleResourceRelateDAO.RelateName + " <=", value,
                "relateName");

            return this;
        }

        public Criteria andRelateNameLessThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.RelateName);
            str.append(" <= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andRelateNameLessThanOrEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.RelateName + " <= ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andRelateNameLike(String value) {
            StringBuffer buffer = new StringBuffer("%");
            buffer.append(value);
            buffer.append("%");
            addCriterion(ISysRoleResourceRelateDAO.RelateName + " like",
                buffer.toString(), "relateName");

            return this;
        }

        public Criteria andRelateNameNotLike(String value) {
            StringBuffer buffer = new StringBuffer("%");
            buffer.append(value);
            buffer.append("%");
            addCriterion(ISysRoleResourceRelateDAO.RelateName + " not like",
                buffer.toString(), "relateName");

            return this;
        }

        public Criteria andRelateNameIn(List<String> values) {
            if (values.size() == 1) {
                return andRelateNameEqualTo(values.get(0));
            } else {
                addCriterion(ISysRoleResourceRelateDAO.RelateName + " in",
                    values, "relateName");

                return this;
            }
        }

        public Criteria andRelateNameNotIn(List<String> values) {
            if (values.size() == 1) {
                return andRelateNameNotEqualTo(values.get(0));
            } else {
                addCriterion(ISysRoleResourceRelateDAO.RelateName + " not in",
                    values, "relateName");

                return this;
            }
        }

        public Criteria andRelateNameIn(String[] values) {
            if (values.length == 1) {
                return andRelateNameEqualTo(values[0]);
            } else {
                addCriterion(ISysRoleResourceRelateDAO.RelateName + " in",
                    Arrays.asList(values), "relateName");

                return this;
            }
        }

        public Criteria andRelateNameNotIn(String[] values) {
            if (values.length == 1) {
                return andRelateNameNotEqualTo(values[0]);
            } else {
                addCriterion(ISysRoleResourceRelateDAO.RelateName + " not in",
                    Arrays.asList(values), "relateName");

                return this;
            }
        }

        public Criteria andRelateNameIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.RelateName + " in ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andRelateNameNotIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.RelateName + " not in ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andRelateNameBetween(String value1, String value2) {
            addCriterion(ISysRoleResourceRelateDAO.RelateName + " between",
                value1, value2, "relateName");

            return this;
        }

        public Criteria andRelateNameNotBetween(String value1, String value2) {
            addCriterion(ISysRoleResourceRelateDAO.RelateName + " not between",
                value1, value2, "relateName");

            return this;
        }

        public Criteria andRemarksIsNull() {
            addCriterion(ISysRoleResourceRelateDAO.Remarks + " is null");

            return this;
        }

        public Criteria andRemarksIsNotNull() {
            addCriterion(ISysRoleResourceRelateDAO.Remarks + " is not null");

            return this;
        }

        public Criteria andRemarksIsNotEmpty() {
            addCriterion(ISysRoleResourceRelateDAO.Remarks +
                " is not null AND " + ISysRoleResourceRelateDAO.Remarks +
                " <> ''");

            return this;
        }

        public Criteria andRemarksIsEmpty() {
            addCriterion("(" + ISysRoleResourceRelateDAO.Remarks +
                " is null OR " + ISysRoleResourceRelateDAO.Remarks + " = '')");

            return this;
        }

        public Criteria andRemarksEqualTo(String value) {
            addCriterion(ISysRoleResourceRelateDAO.Remarks + " = ", value,
                "remarks");

            return this;
        }

        public Criteria andRemarksEqualToForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.Remarks);
            str.append(" = ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andRemarksEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.Remarks + " = ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andRemarksNotEqualTo(String value) {
            addCriterion(ISysRoleResourceRelateDAO.Remarks + " <>", value,
                "remarks");

            return this;
        }

        public Criteria andRemarksNotEqualToOrIsNull(String value) {
            addCriterion(ISysRoleResourceRelateDAO.Remarks + " is null OR " +
                ISysRoleResourceRelateDAO.Remarks + " <>", value, "remarks");

            return this;
        }

        public Criteria andRemarksNotEqualToForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.Remarks);
            str.append(" <> ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andRemarksNotEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.Remarks + " <> ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andRemarksGreaterThan(String value) {
            addCriterion(ISysRoleResourceRelateDAO.Remarks + " >", value,
                "remarks");

            return this;
        }

        public Criteria andRemarksGreaterThanForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.Remarks);
            str.append(" > ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andRemarksGreaterThan(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.Remarks + " > ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andRemarksGreaterThanOrEqualTo(String value) {
            addCriterion(ISysRoleResourceRelateDAO.Remarks + " >=", value,
                "remarks");

            return this;
        }

        public Criteria andRemarksGreaterThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.Remarks);
            str.append(" >= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andRemarksGreaterThanOrEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.Remarks + " >= ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andRemarksLessThan(String value) {
            addCriterion(ISysRoleResourceRelateDAO.Remarks + " <", value,
                "remarks");

            return this;
        }

        public Criteria andRemarksLessThanForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.Remarks);
            str.append(" < ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andRemarksLessThan(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.Remarks + " < ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andRemarksLessThanOrEqualTo(String value) {
            addCriterion(ISysRoleResourceRelateDAO.Remarks + " <=", value,
                "remarks");

            return this;
        }

        public Criteria andRemarksLessThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.Remarks);
            str.append(" <= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andRemarksLessThanOrEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.Remarks + " <= ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andRemarksLike(String value) {
            StringBuffer buffer = new StringBuffer("%");
            buffer.append(value);
            buffer.append("%");
            addCriterion(ISysRoleResourceRelateDAO.Remarks + " like",
                buffer.toString(), "remarks");

            return this;
        }

        public Criteria andRemarksNotLike(String value) {
            StringBuffer buffer = new StringBuffer("%");
            buffer.append(value);
            buffer.append("%");
            addCriterion(ISysRoleResourceRelateDAO.Remarks + " not like",
                buffer.toString(), "remarks");

            return this;
        }

        public Criteria andRemarksIn(List<String> values) {
            if (values.size() == 1) {
                return andRemarksEqualTo(values.get(0));
            } else {
                addCriterion(ISysRoleResourceRelateDAO.Remarks + " in", values,
                    "remarks");

                return this;
            }
        }

        public Criteria andRemarksNotIn(List<String> values) {
            if (values.size() == 1) {
                return andRemarksNotEqualTo(values.get(0));
            } else {
                addCriterion(ISysRoleResourceRelateDAO.Remarks + " not in",
                    values, "remarks");

                return this;
            }
        }

        public Criteria andRemarksIn(String[] values) {
            if (values.length == 1) {
                return andRemarksEqualTo(values[0]);
            } else {
                addCriterion(ISysRoleResourceRelateDAO.Remarks + " in",
                    Arrays.asList(values), "remarks");

                return this;
            }
        }

        public Criteria andRemarksNotIn(String[] values) {
            if (values.length == 1) {
                return andRemarksNotEqualTo(values[0]);
            } else {
                addCriterion(ISysRoleResourceRelateDAO.Remarks + " not in",
                    Arrays.asList(values), "remarks");

                return this;
            }
        }

        public Criteria andRemarksIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.Remarks + " in ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andRemarksNotIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.Remarks + " not in ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andRemarksBetween(String value1, String value2) {
            addCriterion(ISysRoleResourceRelateDAO.Remarks + " between",
                value1, value2, "remarks");

            return this;
        }

        public Criteria andRemarksNotBetween(String value1, String value2) {
            addCriterion(ISysRoleResourceRelateDAO.Remarks + " not between",
                value1, value2, "remarks");

            return this;
        }

        public Criteria andStatusIsNull() {
            addCriterion(ISysRoleResourceRelateDAO.Status + " is null");

            return this;
        }

        public Criteria andStatusIsNotNull() {
            addCriterion(ISysRoleResourceRelateDAO.Status + " is not null");

            return this;
        }

        public Criteria andStatusIsNotEmpty() {
            addCriterion(ISysRoleResourceRelateDAO.Status +
                " is not null AND " + ISysRoleResourceRelateDAO.Status +
                " <> ''");

            return this;
        }

        public Criteria andStatusIsEmpty() {
            addCriterion("(" + ISysRoleResourceRelateDAO.Status +
                " is null OR " + ISysRoleResourceRelateDAO.Status + " = '')");

            return this;
        }

        public Criteria andStatusEqualTo(String value) {
            addCriterion(ISysRoleResourceRelateDAO.Status + " = ", value,
                "status");

            return this;
        }

        public Criteria andStatusEqualToForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.Status);
            str.append(" = ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andStatusEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.Status + " = ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andStatusNotEqualTo(String value) {
            addCriterion(ISysRoleResourceRelateDAO.Status + " <>", value,
                "status");

            return this;
        }

        public Criteria andStatusNotEqualToOrIsNull(String value) {
            addCriterion(ISysRoleResourceRelateDAO.Status + " is null OR " +
                ISysRoleResourceRelateDAO.Status + " <>", value, "status");

            return this;
        }

        public Criteria andStatusNotEqualToForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.Status);
            str.append(" <> ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andStatusNotEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.Status + " <> ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andStatusGreaterThan(String value) {
            addCriterion(ISysRoleResourceRelateDAO.Status + " >", value,
                "status");

            return this;
        }

        public Criteria andStatusGreaterThanForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.Status);
            str.append(" > ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andStatusGreaterThan(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.Status + " > ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andStatusGreaterThanOrEqualTo(String value) {
            addCriterion(ISysRoleResourceRelateDAO.Status + " >=", value,
                "status");

            return this;
        }

        public Criteria andStatusGreaterThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.Status);
            str.append(" >= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andStatusGreaterThanOrEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.Status + " >= ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andStatusLessThan(String value) {
            addCriterion(ISysRoleResourceRelateDAO.Status + " <", value,
                "status");

            return this;
        }

        public Criteria andStatusLessThanForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.Status);
            str.append(" < ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andStatusLessThan(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.Status + " < ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andStatusLessThanOrEqualTo(String value) {
            addCriterion(ISysRoleResourceRelateDAO.Status + " <=", value,
                "status");

            return this;
        }

        public Criteria andStatusLessThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.Status);
            str.append(" <= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andStatusLessThanOrEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.Status + " <= ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andStatusLike(String value) {
            StringBuffer buffer = new StringBuffer("%");
            buffer.append(value);
            buffer.append("%");
            addCriterion(ISysRoleResourceRelateDAO.Status + " like",
                buffer.toString(), "status");

            return this;
        }

        public Criteria andStatusNotLike(String value) {
            StringBuffer buffer = new StringBuffer("%");
            buffer.append(value);
            buffer.append("%");
            addCriterion(ISysRoleResourceRelateDAO.Status + " not like",
                buffer.toString(), "status");

            return this;
        }

        public Criteria andStatusIn(List<String> values) {
            if (values.size() == 1) {
                return andStatusEqualTo(values.get(0));
            } else {
                addCriterion(ISysRoleResourceRelateDAO.Status + " in", values,
                    "status");

                return this;
            }
        }

        public Criteria andStatusNotIn(List<String> values) {
            if (values.size() == 1) {
                return andStatusNotEqualTo(values.get(0));
            } else {
                addCriterion(ISysRoleResourceRelateDAO.Status + " not in",
                    values, "status");

                return this;
            }
        }

        public Criteria andStatusIn(String[] values) {
            if (values.length == 1) {
                return andStatusEqualTo(values[0]);
            } else {
                addCriterion(ISysRoleResourceRelateDAO.Status + " in",
                    Arrays.asList(values), "status");

                return this;
            }
        }

        public Criteria andStatusNotIn(String[] values) {
            if (values.length == 1) {
                return andStatusNotEqualTo(values[0]);
            } else {
                addCriterion(ISysRoleResourceRelateDAO.Status + " not in",
                    Arrays.asList(values), "status");

                return this;
            }
        }

        public Criteria andStatusIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.Status + " in ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andStatusNotIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.Status + " not in ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andStatusBetween(String value1, String value2) {
            addCriterion(ISysRoleResourceRelateDAO.Status + " between", value1,
                value2, "status");

            return this;
        }

        public Criteria andStatusNotBetween(String value1, String value2) {
            addCriterion(ISysRoleResourceRelateDAO.Status + " not between",
                value1, value2, "status");

            return this;
        }

        public Criteria andSysResourceIdIsNull() {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceId + " is null");

            return this;
        }

        public Criteria andSysResourceIdIsNotNull() {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceId +
                " is not null");

            return this;
        }

        public Criteria andSysResourceIdIsNotEmpty() {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceId +
                " is not null AND " + ISysRoleResourceRelateDAO.SysResourceId +
                " <> ''");

            return this;
        }

        public Criteria andSysResourceIdIsEmpty() {
            addCriterion("(" + ISysRoleResourceRelateDAO.SysResourceId +
                " is null OR " + ISysRoleResourceRelateDAO.SysResourceId +
                " = '')");

            return this;
        }

        public Criteria andSysResourceIdEqualTo(long value) {
            return andSysResourceIdEqualTo(Long.valueOf(value));
        }

        public Criteria andSysResourceIdEqualTo(java.lang.Long value) {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceId + " = ",
                value, "sysResourceId");

            return this;
        }

        public Criteria andSysResourceIdEqualToForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.SysResourceId);
            str.append(" = ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andSysResourceIdEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceId + " = ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andSysResourceIdNotEqualTo(long value) {
            return andSysResourceIdNotEqualTo(Long.valueOf(value));
        }

        public Criteria andSysResourceIdNotEqualTo(java.lang.Long value) {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceId + " <>",
                value, "sysResourceId");

            return this;
        }

        public Criteria andSysResourceIdNotEqualToOrIsNull(long value) {
            return andSysResourceIdNotEqualToOrIsNull(Long.valueOf(value));
        }

        public Criteria andSysResourceIdNotEqualToOrIsNull(java.lang.Long value) {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceId +
                " is null OR " + ISysRoleResourceRelateDAO.SysResourceId +
                " <>", value, "sysResourceId");

            return this;
        }

        public Criteria andSysResourceIdNotEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.SysResourceId);
            str.append(" <> ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andSysResourceIdNotEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceId + " <> ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andSysResourceIdGreaterThan(long value) {
            return andSysResourceIdGreaterThan(Long.valueOf(value));
        }

        public Criteria andSysResourceIdGreaterThan(java.lang.Long value) {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceId + " >", value,
                "sysResourceId");

            return this;
        }

        public Criteria andSysResourceIdGreaterThanForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.SysResourceId);
            str.append(" > ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andSysResourceIdGreaterThan(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceId + " > ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andSysResourceIdGreaterThanOrEqualTo(long value) {
            return andSysResourceIdGreaterThanOrEqualTo(Long.valueOf(value));
        }

        public Criteria andSysResourceIdGreaterThanOrEqualTo(
            java.lang.Long value) {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceId + " >=",
                value, "sysResourceId");

            return this;
        }

        public Criteria andSysResourceIdGreaterThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.SysResourceId);
            str.append(" >= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andSysResourceIdGreaterThanOrEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceId + " >= ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andSysResourceIdLessThan(long value) {
            return andSysResourceIdLessThan(Long.valueOf(value));
        }

        public Criteria andSysResourceIdLessThan(java.lang.Long value) {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceId + " <", value,
                "sysResourceId");

            return this;
        }

        public Criteria andSysResourceIdLessThanForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.SysResourceId);
            str.append(" < ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andSysResourceIdLessThan(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceId + " < ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andSysResourceIdLessThanOrEqualTo(long value) {
            return andSysResourceIdLessThanOrEqualTo(Long.valueOf(value));
        }

        public Criteria andSysResourceIdLessThanOrEqualTo(java.lang.Long value) {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceId + " <=",
                value, "sysResourceId");

            return this;
        }

        public Criteria andSysResourceIdLessThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.SysResourceId);
            str.append(" <= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andSysResourceIdLessThanOrEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceId + " <= ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andSysResourceIdIn(long[] values) {
            if (values.length == 1) {
                return andSysResourceIdEqualTo((java.lang.Long) values[0]);
            } else {
                addCriterion(ISysRoleResourceRelateDAO.SysResourceId + " in",
                    values, "sysResourceId");

                return this;
            }
        }

        public Criteria andSysResourceIdNotIn(long[] values) {
            if (values.length == 1) {
                return andSysResourceIdNotEqualTo((java.lang.Long) values[0]);
            } else {
                addCriterion(ISysRoleResourceRelateDAO.SysResourceId +
                    " not in", values, "sysResourceId");

                return this;
            }
        }

        public Criteria andSysResourceIdIn(List<java.lang.Long> values) {
            if (values.size() == 1) {
                return andSysResourceIdEqualTo(values.get(0));
            } else {
                addCriterion(ISysRoleResourceRelateDAO.SysResourceId + " in",
                    values, "sysResourceId");

                return this;
            }
        }

        public Criteria andSysResourceIdNotIn(List<java.lang.Long> values) {
            if (values.size() == 1) {
                return andSysResourceIdNotEqualTo(values.get(0));
            } else {
                addCriterion(ISysRoleResourceRelateDAO.SysResourceId +
                    " not in", values, "sysResourceId");

                return this;
            }
        }

        public Criteria andSysResourceIdIn(java.lang.Long[] values) {
            if (values.length == 1) {
                return andSysResourceIdEqualTo(values[0]);
            } else {
                addCriterion(ISysRoleResourceRelateDAO.SysResourceId + " in",
                    Arrays.asList(values), "sysResourceId");

                return this;
            }
        }

        public Criteria andSysResourceIdNotIn(java.lang.Long[] values) {
            if (values.length == 1) {
                return andSysResourceIdNotEqualTo(values[0]);
            } else {
                addCriterion(ISysRoleResourceRelateDAO.SysResourceId +
                    " not in", Arrays.asList(values), "sysResourceId");

                return this;
            }
        }

        public Criteria andSysResourceIdIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceId + " in ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andSysResourceIdNotIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceId + " not in ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andSysResourceIdBetween(long value1, long value2) {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceId + " between",
                value1, value2, "sysResourceId");

            return this;
        }

        public Criteria andSysResourceIdBetween(java.lang.Long value1,
            java.lang.Long value2) {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceId + " between",
                value1, value2, "sysResourceId");

            return this;
        }

        public Criteria andSysResourceIdNotBetween(long value1, long value2) {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceId +
                " not between", value1, value2, "sysResourceId");

            return this;
        }

        public Criteria andSysResourceIdNotBetween(java.lang.Long value1,
            java.lang.Long value2) {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceId +
                " not between", value1, value2, "sysResourceId");

            return this;
        }

        public Criteria andSysRoleIdIsNull() {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleId + " is null");

            return this;
        }

        public Criteria andSysRoleIdIsNotNull() {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleId + " is not null");

            return this;
        }

        public Criteria andSysRoleIdIsNotEmpty() {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleId +
                " is not null AND " + ISysRoleResourceRelateDAO.SysRoleId +
                " <> ''");

            return this;
        }

        public Criteria andSysRoleIdIsEmpty() {
            addCriterion("(" + ISysRoleResourceRelateDAO.SysRoleId +
                " is null OR " + ISysRoleResourceRelateDAO.SysRoleId +
                " = '')");

            return this;
        }

        public Criteria andSysRoleIdEqualTo(long value) {
            return andSysRoleIdEqualTo(Long.valueOf(value));
        }

        public Criteria andSysRoleIdEqualTo(java.lang.Long value) {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleId + " = ", value,
                "sysRoleId");

            return this;
        }

        public Criteria andSysRoleIdEqualToForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.SysRoleId);
            str.append(" = ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andSysRoleIdEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleId + " = ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andSysRoleIdNotEqualTo(long value) {
            return andSysRoleIdNotEqualTo(Long.valueOf(value));
        }

        public Criteria andSysRoleIdNotEqualTo(java.lang.Long value) {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleId + " <>", value,
                "sysRoleId");

            return this;
        }

        public Criteria andSysRoleIdNotEqualToOrIsNull(long value) {
            return andSysRoleIdNotEqualToOrIsNull(Long.valueOf(value));
        }

        public Criteria andSysRoleIdNotEqualToOrIsNull(java.lang.Long value) {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleId + " is null OR " +
                ISysRoleResourceRelateDAO.SysRoleId + " <>", value, "sysRoleId");

            return this;
        }

        public Criteria andSysRoleIdNotEqualToForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.SysRoleId);
            str.append(" <> ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andSysRoleIdNotEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleId + " <> ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andSysRoleIdGreaterThan(long value) {
            return andSysRoleIdGreaterThan(Long.valueOf(value));
        }

        public Criteria andSysRoleIdGreaterThan(java.lang.Long value) {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleId + " >", value,
                "sysRoleId");

            return this;
        }

        public Criteria andSysRoleIdGreaterThanForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.SysRoleId);
            str.append(" > ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andSysRoleIdGreaterThan(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleId + " > ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andSysRoleIdGreaterThanOrEqualTo(long value) {
            return andSysRoleIdGreaterThanOrEqualTo(Long.valueOf(value));
        }

        public Criteria andSysRoleIdGreaterThanOrEqualTo(java.lang.Long value) {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleId + " >=", value,
                "sysRoleId");

            return this;
        }

        public Criteria andSysRoleIdGreaterThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.SysRoleId);
            str.append(" >= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andSysRoleIdGreaterThanOrEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleId + " >= ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andSysRoleIdLessThan(long value) {
            return andSysRoleIdLessThan(Long.valueOf(value));
        }

        public Criteria andSysRoleIdLessThan(java.lang.Long value) {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleId + " <", value,
                "sysRoleId");

            return this;
        }

        public Criteria andSysRoleIdLessThanForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.SysRoleId);
            str.append(" < ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andSysRoleIdLessThan(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleId + " < ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andSysRoleIdLessThanOrEqualTo(long value) {
            return andSysRoleIdLessThanOrEqualTo(Long.valueOf(value));
        }

        public Criteria andSysRoleIdLessThanOrEqualTo(java.lang.Long value) {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleId + " <=", value,
                "sysRoleId");

            return this;
        }

        public Criteria andSysRoleIdLessThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.SysRoleId);
            str.append(" <= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andSysRoleIdLessThanOrEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleId + " <= ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andSysRoleIdIn(long[] values) {
            if (values.length == 1) {
                return andSysRoleIdEqualTo((java.lang.Long) values[0]);
            } else {
                addCriterion(ISysRoleResourceRelateDAO.SysRoleId + " in",
                    values, "sysRoleId");

                return this;
            }
        }

        public Criteria andSysRoleIdNotIn(long[] values) {
            if (values.length == 1) {
                return andSysRoleIdNotEqualTo((java.lang.Long) values[0]);
            } else {
                addCriterion(ISysRoleResourceRelateDAO.SysRoleId + " not in",
                    values, "sysRoleId");

                return this;
            }
        }

        public Criteria andSysRoleIdIn(List<java.lang.Long> values) {
            if (values.size() == 1) {
                return andSysRoleIdEqualTo(values.get(0));
            } else {
                addCriterion(ISysRoleResourceRelateDAO.SysRoleId + " in",
                    values, "sysRoleId");

                return this;
            }
        }

        public Criteria andSysRoleIdNotIn(List<java.lang.Long> values) {
            if (values.size() == 1) {
                return andSysRoleIdNotEqualTo(values.get(0));
            } else {
                addCriterion(ISysRoleResourceRelateDAO.SysRoleId + " not in",
                    values, "sysRoleId");

                return this;
            }
        }

        public Criteria andSysRoleIdIn(java.lang.Long[] values) {
            if (values.length == 1) {
                return andSysRoleIdEqualTo(values[0]);
            } else {
                addCriterion(ISysRoleResourceRelateDAO.SysRoleId + " in",
                    Arrays.asList(values), "sysRoleId");

                return this;
            }
        }

        public Criteria andSysRoleIdNotIn(java.lang.Long[] values) {
            if (values.length == 1) {
                return andSysRoleIdNotEqualTo(values[0]);
            } else {
                addCriterion(ISysRoleResourceRelateDAO.SysRoleId + " not in",
                    Arrays.asList(values), "sysRoleId");

                return this;
            }
        }

        public Criteria andSysRoleIdIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleId + " in ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andSysRoleIdNotIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleId + " not in ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andSysRoleIdBetween(long value1, long value2) {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleId + " between",
                value1, value2, "sysRoleId");

            return this;
        }

        public Criteria andSysRoleIdBetween(java.lang.Long value1,
            java.lang.Long value2) {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleId + " between",
                value1, value2, "sysRoleId");

            return this;
        }

        public Criteria andSysRoleIdNotBetween(long value1, long value2) {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleId + " not between",
                value1, value2, "sysRoleId");

            return this;
        }

        public Criteria andSysRoleIdNotBetween(java.lang.Long value1,
            java.lang.Long value2) {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleId + " not between",
                value1, value2, "sysRoleId");

            return this;
        }

        public Criteria andSysRoleNameIsNull() {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleName + " is null");

            return this;
        }

        public Criteria andSysRoleNameIsNotNull() {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleName +
                " is not null");

            return this;
        }

        public Criteria andSysRoleNameIsNotEmpty() {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleName +
                " is not null AND " + ISysRoleResourceRelateDAO.SysRoleName +
                " <> ''");

            return this;
        }

        public Criteria andSysRoleNameIsEmpty() {
            addCriterion("(" + ISysRoleResourceRelateDAO.SysRoleName +
                " is null OR " + ISysRoleResourceRelateDAO.SysRoleName +
                " = '')");

            return this;
        }

        public Criteria andSysRoleNameEqualTo(String value) {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleName + " = ", value,
                "sysRoleName");

            return this;
        }

        public Criteria andSysRoleNameEqualToForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.SysRoleName);
            str.append(" = ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andSysRoleNameEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleName + " = ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andSysRoleNameNotEqualTo(String value) {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleName + " <>", value,
                "sysRoleName");

            return this;
        }

        public Criteria andSysRoleNameNotEqualToOrIsNull(String value) {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleName +
                " is null OR " + ISysRoleResourceRelateDAO.SysRoleName + " <>",
                value, "sysRoleName");

            return this;
        }

        public Criteria andSysRoleNameNotEqualToForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.SysRoleName);
            str.append(" <> ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andSysRoleNameNotEqualTo(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleName + " <> ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andSysRoleNameGreaterThan(String value) {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleName + " >", value,
                "sysRoleName");

            return this;
        }

        public Criteria andSysRoleNameGreaterThanForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.SysRoleName);
            str.append(" > ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andSysRoleNameGreaterThan(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleName + " > ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andSysRoleNameGreaterThanOrEqualTo(String value) {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleName + " >=", value,
                "sysRoleName");

            return this;
        }

        public Criteria andSysRoleNameGreaterThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.SysRoleName);
            str.append(" >= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andSysRoleNameGreaterThanOrEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleName + " >= ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andSysRoleNameLessThan(String value) {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleName + " <", value,
                "sysRoleName");

            return this;
        }

        public Criteria andSysRoleNameLessThanForeignKey(java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.SysRoleName);
            str.append(" < ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andSysRoleNameLessThan(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleName + " < ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andSysRoleNameLessThanOrEqualTo(String value) {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleName + " <=", value,
                "sysRoleName");

            return this;
        }

        public Criteria andSysRoleNameLessThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.SysRoleName);
            str.append(" <= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andSysRoleNameLessThanOrEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleName + " <= ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andSysRoleNameLike(String value) {
            StringBuffer buffer = new StringBuffer("%");
            buffer.append(value);
            buffer.append("%");
            addCriterion(ISysRoleResourceRelateDAO.SysRoleName + " like",
                buffer.toString(), "sysRoleName");

            return this;
        }

        public Criteria andSysRoleNameNotLike(String value) {
            StringBuffer buffer = new StringBuffer("%");
            buffer.append(value);
            buffer.append("%");
            addCriterion(ISysRoleResourceRelateDAO.SysRoleName + " not like",
                buffer.toString(), "sysRoleName");

            return this;
        }

        public Criteria andSysRoleNameIn(List<String> values) {
            if (values.size() == 1) {
                return andSysRoleNameEqualTo(values.get(0));
            } else {
                addCriterion(ISysRoleResourceRelateDAO.SysRoleName + " in",
                    values, "sysRoleName");

                return this;
            }
        }

        public Criteria andSysRoleNameNotIn(List<String> values) {
            if (values.size() == 1) {
                return andSysRoleNameNotEqualTo(values.get(0));
            } else {
                addCriterion(ISysRoleResourceRelateDAO.SysRoleName + " not in",
                    values, "sysRoleName");

                return this;
            }
        }

        public Criteria andSysRoleNameIn(String[] values) {
            if (values.length == 1) {
                return andSysRoleNameEqualTo(values[0]);
            } else {
                addCriterion(ISysRoleResourceRelateDAO.SysRoleName + " in",
                    Arrays.asList(values), "sysRoleName");

                return this;
            }
        }

        public Criteria andSysRoleNameNotIn(String[] values) {
            if (values.length == 1) {
                return andSysRoleNameNotEqualTo(values[0]);
            } else {
                addCriterion(ISysRoleResourceRelateDAO.SysRoleName + " not in",
                    Arrays.asList(values), "sysRoleName");

                return this;
            }
        }

        public Criteria andSysRoleNameIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleName + " in ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andSysRoleNameNotIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleName + " not in ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andSysRoleNameBetween(String value1, String value2) {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleName + " between",
                value1, value2, "sysRoleName");

            return this;
        }

        public Criteria andSysRoleNameNotBetween(String value1, String value2) {
            addCriterion(ISysRoleResourceRelateDAO.SysRoleName +
                " not between", value1, value2, "sysRoleName");

            return this;
        }

        public Criteria andSysResourceTitleKeyIsNull() {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceTitleKey +
                " is null");

            return this;
        }

        public Criteria andSysResourceTitleKeyIsNotNull() {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceTitleKey +
                " is not null");

            return this;
        }

        public Criteria andSysResourceTitleKeyIsNotEmpty() {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceTitleKey +
                " is not null AND " +
                ISysRoleResourceRelateDAO.SysResourceTitleKey + " <> ''");

            return this;
        }

        public Criteria andSysResourceTitleKeyIsEmpty() {
            addCriterion("(" + ISysRoleResourceRelateDAO.SysResourceTitleKey +
                " is null OR " + ISysRoleResourceRelateDAO.SysResourceTitleKey +
                " = '')");

            return this;
        }

        public Criteria andSysResourceTitleKeyEqualTo(String value) {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceTitleKey + " = ",
                value, "sysResourceTitleKey");

            return this;
        }

        public Criteria andSysResourceTitleKeyEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.SysResourceTitleKey);
            str.append(" = ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andSysResourceTitleKeyEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceTitleKey + " = ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andSysResourceTitleKeyNotEqualTo(String value) {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceTitleKey + " <>",
                value, "sysResourceTitleKey");

            return this;
        }

        public Criteria andSysResourceTitleKeyNotEqualToOrIsNull(String value) {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceTitleKey +
                " is null OR " + ISysRoleResourceRelateDAO.SysResourceTitleKey +
                " <>", value, "sysResourceTitleKey");

            return this;
        }

        public Criteria andSysResourceTitleKeyNotEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.SysResourceTitleKey);
            str.append(" <> ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andSysResourceTitleKeyNotEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceTitleKey +
                " <> ", subQueryBean, dao);

            return this;
        }

        public Criteria andSysResourceTitleKeyGreaterThan(String value) {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceTitleKey + " >",
                value, "sysResourceTitleKey");

            return this;
        }

        public Criteria andSysResourceTitleKeyGreaterThanForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.SysResourceTitleKey);
            str.append(" > ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andSysResourceTitleKeyGreaterThan(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceTitleKey + " > ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andSysResourceTitleKeyGreaterThanOrEqualTo(String value) {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceTitleKey + " >=",
                value, "sysResourceTitleKey");

            return this;
        }

        public Criteria andSysResourceTitleKeyGreaterThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.SysResourceTitleKey);
            str.append(" >= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andSysResourceTitleKeyGreaterThanOrEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceTitleKey +
                " >= ", subQueryBean, dao);

            return this;
        }

        public Criteria andSysResourceTitleKeyLessThan(String value) {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceTitleKey + " <",
                value, "sysResourceTitleKey");

            return this;
        }

        public Criteria andSysResourceTitleKeyLessThanForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.SysResourceTitleKey);
            str.append(" < ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andSysResourceTitleKeyLessThan(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceTitleKey + " < ",
                subQueryBean, dao);

            return this;
        }

        public Criteria andSysResourceTitleKeyLessThanOrEqualTo(String value) {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceTitleKey + " <=",
                value, "sysResourceTitleKey");

            return this;
        }

        public Criteria andSysResourceTitleKeyLessThanOrEqualToForeignKey(
            java.lang.String key) {
            StringBuffer str = new StringBuffer(ISysRoleResourceRelateDAO.SysResourceTitleKey);
            str.append(" <= ").append(key);
            addForeignKeyCriterion(str.toString());

            return this;
        }

        public Criteria andSysResourceTitleKeyLessThanOrEqualTo(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceTitleKey +
                " <= ", subQueryBean, dao);

            return this;
        }

        public Criteria andSysResourceTitleKeyLike(String value) {
            StringBuffer buffer = new StringBuffer("%");
            buffer.append(value);
            buffer.append("%");
            addCriterion(ISysRoleResourceRelateDAO.SysResourceTitleKey +
                " like", buffer.toString(), "sysResourceTitleKey");

            return this;
        }

        public Criteria andSysResourceTitleKeyNotLike(String value) {
            StringBuffer buffer = new StringBuffer("%");
            buffer.append(value);
            buffer.append("%");
            addCriterion(ISysRoleResourceRelateDAO.SysResourceTitleKey +
                " not like", buffer.toString(), "sysResourceTitleKey");

            return this;
        }

        public Criteria andSysResourceTitleKeyIn(List<String> values) {
            if (values.size() == 1) {
                return andSysResourceTitleKeyEqualTo(values.get(0));
            } else {
                addCriterion(ISysRoleResourceRelateDAO.SysResourceTitleKey +
                    " in", values, "sysResourceTitleKey");

                return this;
            }
        }

        public Criteria andSysResourceTitleKeyNotIn(List<String> values) {
            if (values.size() == 1) {
                return andSysResourceTitleKeyNotEqualTo(values.get(0));
            } else {
                addCriterion(ISysRoleResourceRelateDAO.SysResourceTitleKey +
                    " not in", values, "sysResourceTitleKey");

                return this;
            }
        }

        public Criteria andSysResourceTitleKeyIn(String[] values) {
            if (values.length == 1) {
                return andSysResourceTitleKeyEqualTo(values[0]);
            } else {
                addCriterion(ISysRoleResourceRelateDAO.SysResourceTitleKey +
                    " in", Arrays.asList(values), "sysResourceTitleKey");

                return this;
            }
        }

        public Criteria andSysResourceTitleKeyNotIn(String[] values) {
            if (values.length == 1) {
                return andSysResourceTitleKeyNotEqualTo(values[0]);
            } else {
                addCriterion(ISysRoleResourceRelateDAO.SysResourceTitleKey +
                    " not in", Arrays.asList(values), "sysResourceTitleKey");

                return this;
            }
        }

        public Criteria andSysResourceTitleKeyIn(BaseQueryBean subQueryBean,
            IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceTitleKey +
                " in ", subQueryBean, dao);

            return this;
        }

        public Criteria andSysResourceTitleKeyNotIn(
            BaseQueryBean subQueryBean, IDataAccessInterface<?, ?> dao) {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceTitleKey +
                " not in ", subQueryBean, dao);

            return this;
        }

        public Criteria andSysResourceTitleKeyBetween(String value1,
            String value2) {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceTitleKey +
                " between", value1, value2, "sysResourceTitleKey");

            return this;
        }

        public Criteria andSysResourceTitleKeyNotBetween(String value1,
            String value2) {
            addCriterion(ISysRoleResourceRelateDAO.SysResourceTitleKey +
                " not between", value1, value2, "sysResourceTitleKey");

            return this;
        }
    }
}
